function bodymodel
    v = [0,1,0]; % right hand side vector(unit)
    s0 = [0,0,180];
    n = [[-1,2,-1];[1,1,1];[1,1,0];[-1,-1,0];[0,2,1];[0,-2,-1];[1,0,-1];[0,1,-1];[1,1,-1];[-1,0,-1]]; % 10
    l = [30,20,20,20,40,40]; % 6
    mu = [20,10,5,5,10,10]; % 6

    close all;

    % c0 body
    n0 = n(1,:);
    l0 = l(1);
    mu0 = mu(1);
    s0;
    e0 = s0 + l0*n0;

    % c1 head
    n1 = n(2,:);
    l1 = l(2);
    mu1 = mu(2);
    s1 = s0;
    e1 = s1 + n1*l1;

    % c2 upper right arm
    n2 = n(3,:);
    l2 = l(3);
    mu2 = mu(3);
    s2 = s0 + n0*mu2 + v*mu0;
    e2 = s2 + n2*l2;

    % c3 upper left arm
    n3 = n(4,:);
    l3 = l2;
    mu3 = mu2;
    s3 = s0 + n0*mu3 - v*mu0;
    e3 = s3 + n3*l3;

    % c4 lower right arm
    n4 = n(5,:);
    l4 = l(4);
    mu4 = mu(4);
    s4 = e2;
    e4 = s4 + n4*l4;

    % c5 lower left arm
    n5 = n(6,:);
    l5 = l4;
    mu5 = mu4;
    s5 = e3;
    e5 = s5 + n5*l5;

    % c6 upper right leg
    n6 = n(7,:);
    l6 = l(5);
    mu6 = mu(5);
    s6 = e0 + (mu0-mu6)*v;
    e6 = s6 + n6*l6;

    % c7 upper left leg
    n7 = n(8,:);
    l7 = l6;
    mu7 = mu6;
    s7 = e0 - (mu0-mu7)*v;
    e7 = s7 + n7*l7;

    % c8 lower right leg
    n8 = n(9,:);
    l8 = l(6);
    mu8 = mu(6);
    s8 = e6;
    e8 = s8 + n8*l8;

    % c9 lower left leg
    n9 = n(10,:);
    l9 = l8;
    mu9 = mu8;
    s9 = e7;
    e9 = s9 + n9*l9;

    plot3([s0(1),e0(1)],[s0(2),e0(2)],[s0(3),e0(3)],'LineWidth',2);hold on;
    plot3([s1(1),e1(1)],[s1(2),e1(2)],[s1(3),e1(3)],'LineWidth',2);hold on;
    plot3([s2(1),e2(1)],[s2(2),e2(2)],[s2(3),e2(3)],'r','LineWidth',2);hold on;
    plot3([s3(1),e3(1)],[s3(2),e3(2)],[s3(3),e3(3)],'b','LineWidth',2);hold on;
    plot3([s4(1),e4(1)],[s4(2),e4(2)],[s4(3),e4(3)],'r','LineWidth',2);hold on;
    plot3([s5(1),e5(1)],[s5(2),e5(2)],[s5(3),e5(3)],'b','LineWidth',2);hold on;
    plot3([s6(1),e6(1)],[s6(2),e6(2)],[s6(3),e6(3)],'r','LineWidth',2);hold on;
    plot3([s7(1),e7(1)],[s7(2),e7(2)],[s7(3),e7(3)],'b','LineWidth',2);hold on;
    plot3([s8(1),e8(1)],[s8(2),e8(2)],[s8(3),e8(3)],'r','LineWidth',2);hold on;
    plot3([s9(1),e9(1)],[s9(2),e9(2)],[s9(3),e9(3)],'b','LineWidth',2);
    axis equal
end
